import { BrowserRouter } from 'react-router-dom'
import Router from './router/Index'
import style from './App.module.less'
import AuthGuard from './router/AuthGuard'
import { Button } from 'antd'
import { useAppSelector } from './hooks/store'

function App() {
  const token = useAppSelector(({ global }) => global.token)

  return (
    <div className="App">
      <BrowserRouter>
        <AuthGuard>
          <Router></Router>
        </AuthGuard>
        <div className={style.test}>测试less模块化</div>
        <div>{token}</div>
        <Button type="primary">测试按钮</Button>
      </BrowserRouter>
    </div>
  )
}

export default App
